package com.battery.system.mapper;

import com.battery.system.base.BaseMapper;
import com.battery.system.domain.BO.EndorderBO;
import com.battery.system.domain.Endorder;
import com.battery.system.domain.VO.EndorderVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 订单强制结束申请Mapper接口
 *
 * @author battery
 * @date 2021-03-12
 */
public interface EndorderMapper extends BaseMapper<Endorder> {
    /**
     * 查询订单强制结束申请
     *
     * @param id 订单强制结束申请ID
     * @return 订单强制结束申请
     */
    public Endorder selectEndorderById(String id);

    /**
     * 查询订单强制结束申请列表
     *
     * @param endorder 订单强制结束申请
     * @return 订单强制结束申请集合
     */
    public List<Endorder> selectEndorderList(Endorder endorder);

    /**
     * 新增订单强制结束申请
     *
     * @param endorder 订单强制结束申请
     * @return 结果
     */
    public int insertEndorder(Endorder endorder);

    /**
     * 修改订单强制结束申请
     *
     * @param endorder 订单强制结束申请
     * @return 结果
     */
    public int updateEndorder(Endorder endorder);

    /**
     * 删除订单强制结束申请
     *
     * @param id 订单强制结束申请ID
     * @return 结果
     */
    public int deleteEndorderById(String id);

    /**
     * 批量删除订单强制结束申请
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    public int deleteEndorderByIds(String[] ids);

    List<Endorder> selectEndorderByPartner(@Param("map") Map<String, String> map);

    /**
     * 展示申请结束顶顶那列表
     *
     * @param endorderBO
     * @return
     */
    List<EndorderVO> selectEndorderVOList(@Param("endorderBO") EndorderBO endorderBO);

    /**
     *
     * @param usedId
     * @return
     */
    Endorder selectOneByUsedId(String usedId);
}
